package com.ssy.lingxi.platform.manage.api.feign.paas;


import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.platform.manage.api.hystrix.paas.ShopPAASControllerFeignFallback;
import com.ssy.lingxi.platform.manage.api.model.dto.shop.ShopPAASDTO;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @menu 商城 - （系统初始化）PAAS接口
 * @author fhj
 * @version 2.0.0
 * @date 2020/07/23
 */
@FeignClient(value = "platform-manage-service", fallback = ShopPAASControllerFeignFallback.class)
public interface ShopPAASControllerFeign {

    @ApiOperation(value = "新增")
    @PostMapping("/manage/paas/shopPAAS/add")
    Wrapper<?> add(@RequestBody ShopPAASDTO dto);

    @ApiOperation(value = "修改")
    @PostMapping("/manage/paas/shopPAAS/update")
    Wrapper<?> update(@RequestBody ShopPAASDTO dto);

    @ApiOperation(value = "停用/启用")
    @PostMapping("/manage/paas/shopPAAS/stop/start")
    Wrapper<?> stopAndStart(@RequestBody ShopPAASDTO dto);

    @ApiOperation(value = "删除")
    @PostMapping("/manage/paas/shopPAAS/delete")
    Wrapper<?> delete(@RequestBody ShopPAASDTO dto);

    @GetMapping("/manage/shop/findShopsBySiteId")
    Wrapper<?> findShopsBySiteId(@RequestParam(value = "siteId") Long siteId);
}
